﻿Imports Mysoft.Map.Data

Partial Public Class SelectProcessAuditors
    Inherits System.Web.UI.Page

    Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
        If Not IsPostBack Then
            repLD.DataSource = MyDB.GetDataTable(String.Format("SELECT spe.StepPathID,spe.StepName,isnull(ne.Handler,ne.Auditor) Auditor,isNull(ne.HandlerName,ne.AuditorName) AuditorName,ms.BUName,ms.StationName,mu.UserCode FROM myWorkflowNodeEntity ne INNER JOIN myWorkflowStepPathEntity spe ON spe.StepPathGUID = ne.StepPathGUID LEFT JOIN (SELECT s.StationGUID,s.StationName,b.BUGUID,b.BUName FROM myStation s JOIN myBusinessUnit b on b.BUGUID = s.BUGUID) ms ON ms.StationGUID = ne.StationGUID LEFT JOIN myUser mu ON mu.UserGUID = ne.Auditor WHERE ne.NodeStatus<>0 AND ne.NodeStatus<>1 AND ne.NodeStatus<>2 AND ne.ProcessGUID='{0}' ORDER BY spe.StepPathID,mu.UserCode ASC", Request.QueryString("processGUID").ToString()))
            repLD.DataBind()
        End If
    End Sub
End Class